package topdown;

import org.junit.Test;

import junit.framework.Assert;

public class CopyOfCalculatorTest {
	
	@Test(expected=IllegalArgumentException.class)
	public void tambahArgumenPertama(){
		Calculator c = new Calculator();
		
		Integer x = null;
		Integer y = 15;
		
		c.tambah(x,y);
		
		//Assert.assertEquals(new Integer(25), hasil);
	}
	
	@Test(expected=IllegalArgumentException.class)
	public void tambahArgumenKedua(){
		Calculator c = new Calculator();
		
		Integer x = 15;
		Integer y = null;
		
		c.tambah(x,y);
		//Assert.assertEquals(new Integer(5), hasil);
	}
	
	@Test(expected=IllegalArgumentException.class)
	public void bagiNol(){
		Calculator c = new Calculator();
		
		Double x = 10d;
		Double y = 0d;
		
		Double hasil = c.bagi(1d,0d);
		
	}
	

}
